package client;

import java.awt.Graphics;

import client.states.LoadingScreen;

import com.jpemartin.jgt.KeyboardStatus;

/**
 * 
 * @author Robz
 *
 */
public class StateContext {
	private IGameState gameState; 
	
	public StateContext() {
		setState(new LoadingScreen()); 
	} 
 
	public void setState(IGameState newState) { 
		this.gameState = newState; 
	}
 
	public void paint(Graphics g, int GameTime) { 
		this.gameState.paint(g, this, GameTime); 
	}
	
	public void processKeyHit(KeyboardStatus status) { 	
		this.gameState.processKeyHit(this, status); 
	} 
}
